package code.jzh.monitor.entity.methodinvoke;

public class MessageInvokeRecord {
	int depth;
	long startTime;
	long period;
	String methodName;
	boolean throwException;
	
	public MessageInvokeRecord(int depth, long startTime,String methodName) {
		this.depth = depth;
		this.startTime = startTime;
		this.period = Long.MAX_VALUE;
		this.methodName = methodName;
		this.throwException = false;
	}
	
	public MessageInvokeRecord(int depth, long startTime, long period,String methodName) {
		this.depth = depth;
		this.startTime = startTime;
		this.period = period;
		this.methodName = methodName;
		this.throwException = false;
	}
	
	public int getDepth() {
		return depth;
	}
	public void setDepth(int depth) {
		this.depth = depth;
	}
	public long getStartTime() {
		return startTime;
	}
	public void setStartTime(long startTime) {
		this.startTime = startTime;
	}
	
	
	public long getPeriod() {
		return period;
	}
	public void setPeriod(long period) {
		this.period = period;
	}
	
	public String getMethodName() {
		return methodName;
	}

	public void setMethodName(String methodName) {
		this.methodName = methodName;
	}
	
	public boolean isThrowException() {
		return throwException;
	}

	public void setThrowException(boolean throwException) {
		this.throwException = throwException;
	}

	public String toString(){
		return "depth:"+depth+" startTime:"+startTime+" period:"+period+" method:"+methodName
				+ " throwException:"+throwException;
	}
	
}
